'use strict';
const logger = require('../lib/logger').logger;

const log = require('../model/log');

exports.saveReq = function * () {
  const logs = this.request.body;
  logger.info(logs);
  yield log.saveReq(logs);
  return this.body = 'log saved';
};

exports.saveRes = function * () {
  const logs = this.request.body;
  logger.info('res: ', logs);
  yield log.saveRes(logs);
  return this.body = 'log saved';
};
